Kanzi 4.0.0-beta2
kanzi::ListBoxConcept Class Referenceabstract

Properties and messages for list boxes. More...

#include <kanzi/ui/node/concept/list_box.hpp>

Inheritance diagram for kanzi::ListBoxConcept:
[legend]

Classes

class  ItemLoadedMessageArguments
 Message arguments for the messages about the new loaded item in a List Box node. More...
 
class  ItemMessageArguments
 Base class for item-related message arguments. More...
 
class  ItemSelectedMessageArguments
 Message arguments for the messages about the item selected event in a List Box node. More...
 
class  ItemUnloadedMessageArguments
 Message arguments for the messages about item unloading in a List Box node. More...
 
class  MoveFocusMessageArguments
 Message arguments for the message about the focus move execution received on a List Box node. More...
 
class  TrySetFocusToItemMessageArguments
 Message arguments for the message about the set focus execution received on a List Box node. More...
 

Public Types

enum class  FocusMoveTarget {
  NextItem , PreviousItem , NextPage , PreviousPage ,
  LastItem , FirstItem
}
 Specifies the targets to which the focus can move in a List Box. More...
 
enum  SelectionBehavior { SelectionBehaviorNone , SelectionBehaviorBringToCenter }
 Behaviors for the List Box when an item in the List Box is selected. More...
 

Public Member Functions

virtual void notifyItemAdded (size_t index)=0
 Virtual functions for notifying item changes to list.
 
virtual void notifyItemCountChanged ()=0
 
virtual void notifyItemRemoved (size_t index)=0
 
virtual void notifyItemReplaced (size_t index)=0
 
- Public Member Functions inherited from kanzi::ContentItemCollectionModel
virtual bool addContentItem (NodeSharedPtr abstractItem)=0
 
virtual NodeSharedPtr getContentItem (size_t index)=0
 
virtual size_t getContentItemCount ()=0
 
virtual void removeAllContentItems ()=0
 
virtual bool removeContentItem (NodeSharedPtr abstractItem)=0
 
virtual ~ContentItemCollectionModel ()
 

Static Public Member Functions

static PropertyTypeEditorInfoSharedPtr makeEditorInfo ()
 

Static Public Attributes

static MessageType< ItemLoadedMessageArgumentsItemLoadedMessage
 List Box node dispatches this message whenever the List Box loads one of its items.
 
static MessageType< ItemSelectedMessageArgumentsItemSelectedMessage
 List Box node dispatches this message whenever an item in the List Box is selected.
 
static MessageType< ItemUnloadedMessageArgumentsItemUnloadedMessage
 List Box node dispatches this message whenever the List Box unloads one of its items.
 
Properties
static PropertyType< intItemCountProperty
 Reports the number of items in a List Box, including virtual items.
 
static PropertyType< intKeepAliveItemCountProperty
 Sets the size of the buffer for invisible List Box items.
 
static PropertyType< ListBoxConcept::SelectionBehaviorSelectionBehaviorProperty
 Sets how a List Box node behaves when the user selects an item.
 
static PropertyType< string > ItemGeneratorTypeNameProperty
 Sets the name of the item generator type to use to provide items dynamically for a List Box node.
 
static PropertyType< string > ItemContainerGeneratorTypeNameProperty
 Sets the name of the item container generator type to use to provide item containers dynamically for a List Box node.
 
static PropertyType< ResourceSharedPtrItemTemplateProperty
 Sets the prefab template to use for the List Box items.
 
static PropertyType< ResourceSharedPtrItemContainerTemplateProperty
 Sets the ListBoxItemContainer prefab that sets the appearance and behavior of the List Box items.
 
static PropertyType< intSelectedItemIndexProperty
 Sets and reports the index of the item that is currently selected in a List Box node.
 
Actions
static MessageType< TrySetFocusToItemMessageArgumentsTrySetFocusToListItemMessage
 Dispatch this message to set the focus to the list item at a given index.
 
static MessageType< MoveFocusMessageArgumentsMoveFocusMessage
 Dispatch this message to move the focus between List Box items to a given target.
 

Detailed Description

Properties and messages for list boxes.

See also
For general documentation about list boxes, see ListBoxConceptImpl.

Member Enumeration Documentation

◆ SelectionBehavior

Behaviors for the List Box when an item in the List Box is selected.

Enumerator
SelectionBehaviorNone 

When the selection changes, List Box does not change item positions in the list box area.

SelectionBehaviorBringToCenter 

List Box brings selected item to the center of the list box area.

◆ FocusMoveTarget

Specifies the targets to which the focus can move in a List Box.

Since
Kanzi 4.0.0
Enumerator
NextItem 

Moves the focus to the next focusable item.

PreviousItem 

Moves the focus to the previous focusable item.

NextPage 

Moves the focus forward by one page.

One page corresponds to the amount of items that fit in the visible List Box area.

PreviousPage 

Moves the focus backward by one page.

One page corresponds to the amount of items that fit in the visible List Box area.

LastItem 

Moves the focus to the last focusable item.

FirstItem 

Moves the focus to the first focusable item.

Member Function Documentation

◆ notifyItemAdded()

◆ notifyItemRemoved()

◆ notifyItemReplaced()

◆ notifyItemCountChanged()

◆ makeEditorInfo()

static PropertyTypeEditorInfoSharedPtr kanzi::ListBoxConcept::makeEditorInfo ( )
static

Member Data Documentation

◆ ItemCountProperty

PropertyType<int> kanzi::ListBoxConcept::ItemCountProperty
static

Reports the number of items in a List Box, including virtual items.

This property is read-only.

The default value is 0.

See also
ListBoxConceptImpl::getItemCount()

◆ KeepAliveItemCountProperty

PropertyType<int> kanzi::ListBoxConcept::KeepAliveItemCountProperty
static

Sets the size of the buffer for invisible List Box items.

Kanzi returns to the item generator those invisible items that do not fit in the buffer.

The default value is 20000000.

See also
ListBoxConceptImpl::setKeepAliveItemCount(), ListBoxConceptImpl::getKeepAliveItemCount()

◆ SelectionBehaviorProperty

PropertyType<ListBoxConcept::SelectionBehavior> kanzi::ListBoxConcept::SelectionBehaviorProperty
static

Sets how a List Box node behaves when the user selects an item.

ListBoxConcept::SelectionBehaviorBringToCenter sets the List Box to bring an item to the center of the List Box area when the user selects that item.

The default value is ListBoxConcept::SelectionBehaviorNone.

See also
ListBoxConceptImpl::setSelectionBehavior(), ListBoxConceptImpl::getSelectionBehavior()

◆ ItemGeneratorTypeNameProperty

PropertyType<string> kanzi::ListBoxConcept::ItemGeneratorTypeNameProperty
static

Sets the name of the item generator type to use to provide items dynamically for a List Box node.

The default value is "".

See also
ListBoxConceptImpl::setItemGeneratorTypeName(), ListBoxConceptImpl::getItemGeneratorTypeName()

◆ ItemContainerGeneratorTypeNameProperty

PropertyType<string> kanzi::ListBoxConcept::ItemContainerGeneratorTypeNameProperty
static

Sets the name of the item container generator type to use to provide item containers dynamically for a List Box node.

The default value is "".

See also
ListBoxConceptImpl::setItemContainerGeneratorTypeName(), ListBoxConceptImpl::getItemContainerGeneratorTypeName()

◆ ItemTemplateProperty

PropertyType<ResourceSharedPtr> kanzi::ListBoxConcept::ItemTemplateProperty
static

Sets the prefab template to use for the List Box items.

The default value is ResourceSharedPtr().

See also
ListBoxConceptImpl::setItemTemplate(), ListBoxConceptImpl::getItemTemplate()

◆ ItemContainerTemplateProperty

PropertyType<ResourceSharedPtr> kanzi::ListBoxConcept::ItemContainerTemplateProperty
static

Sets the ListBoxItemContainer prefab that sets the appearance and behavior of the List Box items.

The default value is ResourceSharedPtr().

See also
ListBoxConceptImpl::setItemContainerTemplate(), ListBoxConceptImpl::getItemContainerTemplate()

◆ SelectedItemIndexProperty

PropertyType<int> kanzi::ListBoxConcept::SelectedItemIndexProperty
static

Sets and reports the index of the item that is currently selected in a List Box node.

A List Box node updates this property when the user browses that List Box node. By setting the value of this property to the index of the item that you want to select in a List Box, you can select that item.

To update this property with a binding, use a ToSourceBinding or TwoWayBinding. Kanzi overrides any one-way binding that targets this property.

The default value is -1.

See also
ListBoxConceptImpl::setSelectedItemIndex(), ListBoxConceptImpl::getSelectedItemIndex()

◆ ItemSelectedMessage

MessageType<ItemSelectedMessageArguments> kanzi::ListBoxConcept::ItemSelectedMessage
static

List Box node dispatches this message whenever an item in the List Box is selected.

This message type contains the selected item index and previously selected item index.

◆ ItemLoadedMessage

MessageType<ItemLoadedMessageArguments> kanzi::ListBoxConcept::ItemLoadedMessage
static

List Box node dispatches this message whenever the List Box loads one of its items.

This message type contains the item index and the pointer to the loaded item.

◆ ItemUnloadedMessage

MessageType<ItemUnloadedMessageArguments> kanzi::ListBoxConcept::ItemUnloadedMessage
static

List Box node dispatches this message whenever the List Box unloads one of its items.

This message type contains the item index and the pointer to the unloaded item.

◆ TrySetFocusToListItemMessage

MessageType<TrySetFocusToItemMessageArguments> kanzi::ListBoxConcept::TrySetFocusToListItemMessage
static

Dispatch this message to set the focus to the list item at a given index.

Since
Kanzi 4.0.0

◆ MoveFocusMessage

MessageType<MoveFocusMessageArguments> kanzi::ListBoxConcept::MoveFocusMessage
static

Dispatch this message to move the focus between List Box items to a given target.

Since
Kanzi 4.0.0

The documentation for this class was generated from the following file: